﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

public partial class forget_adm : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {
        
    }

    protected void Button1_Click(object sender, EventArgs e)
    {
        if (txtxm.Text== "admin")
        {
            if (func.isadmtrue(txtxm.Text.Trim(), txtid.Text.Trim()))
            {
                string c = null;
                c = func.getadmcode(txtxm.Text.Trim(), txtid.Text.Trim());
                Response.Write("<script>alert('密码为" + c + "请牢记密码');location.href='login_admir.aspx';</script>");

            }
            else
            {
                Response.Write("<script>alert('身份验证号错误')</script>");

            }

        }
        else
        {
            Response.Write("<script>alert('不存在该管理员')</script>");

        }
    }
}